#ifndef CHARTVIEW_H
#define CHARTVIEW_H

#include <QGraphicsView>
#include <QKeyEvent>
#include <QSplitter>
#include <Qt>
#include <QWheelEvent>
#include <QSize>
#include <QRect>

class ChartView : public QGraphicsView
{
    Q_OBJECT
public:
    ChartView(QGraphicsScene *scene);
public slots:
    void zoomin();
    void zoomout();
    void move(int mx);
private:
    QMatrix matrix;
protected:
    //void wheelEvent(QWheelEvent *wheelZoom);
    //void keyPressEvent(QKeyEvent *e);
};

class ChartSplitter : public QSplitter
{
    Q_OBJECT
public:
    ChartSplitter(QWidget *parent =0);

signals:
    void zoomin();
    void zoomout();

protected:
    void keyPressEvent(QKeyEvent *keyZoom);
    void wheelEvent(QWheelEvent *wheelZoom);
};

#endif // CHARTVIEW_H
